Closure function in Route